Open
Conversation
- Add SwitchbotPermanentOutdoorLight device class with RGBIC effects and RGBICStripLightColorMode-based color_mode property - Register POL model enum, adv_parser entries (service data 0xd0b7), and public API export - Fix missing RGBICStripLightColorMode.EFFECT mapping in color mode map - Add defensive bounds check in process_light for short manufacturer data - Add unit tests: POL in parametrized device_case fixture and dedicated color_mode test covering all RGBICStripLightColorMode values (100% coverage) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests.
... and 3 files with indirect coverage changes 🚀 New features to boost your workflow:
|
- Add POL active, passive, and minimum_info adv parser test cases - Add passive test with short manufacturer data (13 bytes) to cover the cw=0 fallback branch in process_light - 100% coverage on adv_parsers/light_strip.py Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add support for the SwitchBot Permanent Outdoor Light (POL) device — an encrypted RGBIC-based outdoor light strip.
Changes
Features
SwitchbotPermanentOutdoorLightdevice class with RGBIC effects andRGBICStripLightColorMode-basedcolor_modepropertyPERMANENT_OUTDOOR_LIGHTmodel enum inSwitchbotModel0xd0b7(both0x00and0x01prefixes)SwitchbotPermanentOutdoorLightin public APIBug Fixes
RGBICStripLightColorMode.EFFECT(value 7) mapping in_RGBICWW_STRIP_LIGHT_COLOR_MODE_MAP— this also fixes a potentialValueErrorfor existing RGBIC strip lightsprocess_lightfor short manufacturer data to avoidIndexErrorTests
device_casefixture (covers all existing strip light tests)test_permanent_outdoor_light_color_modetest covering allRGBICStripLightColorModevalueslight_strip.py